Ext.define('Siga.view.inscripcion.Formulario', {
    extend: 'Ext.window.Window',
    alias: 'widget.contactoform',
    requires: [
        'Ext.layout.container.Border',
        'Siga.view.inscripcion.Tab'
    ],
    title: 'Editar/Crear Contacto',
    width: 280,
    iconCls: 'icon-user',
    initComponent: function() {
        this.items = [{
                xtype: 'form',
                padding: '5 5 0 5',
                border: false,
                style: 'background-color: #fff;',
                fieldDefaults: {
                    anchor: '100%',
                    labelAlign: 'left',
                    allowBlank: false,
                    combineErrors: true,
                    msgTarget: 'side'
                },
                items: [{
                        xtype: 'textfield',
                        name: 'id',
                        fieldLabel: 'id',
                        hidden: true
                    }, {
                        xtype: 'textfield',
                        name: 'name',
                        fieldLabel: 'Nombre'
                    }, {
                        xtype: 'textfield',
                        name: 'phone',
                        fieldLabel: 'Tel\u00E9fono'
                    }, {
                        xtype: 'textfield',
                        name: 'email',
                        fieldLabel: 'Email'
                    },
                    {
                        id: 'app-foter',
                        xtype: 'informacion',
                        region: 'east',
                        height: 250,
                        minHeight: 250,
                        maxHeight: 250,
                        html: '<p>Footer content</p>'
                    }
                ]
            }];
        this.dockedItems = [{
                xtype: 'toolbar',
                dock: 'bottom',
                id: 'buttons',
                ui: 'footer',
                items: ['->', {
                        iconCls: 'icon-save',
                        text: 'Guardar',
                        action: 'guardar'
                    }, {
                        iconCls: 'icon-reset',
                        text: 'Cancelar',
                        scope: this,
                        handler: this.close
                    }
                ]
            }];
        this.callParent(arguments);
    }
});